<?php

namespace Part08_FactoryMethodModel\Code4;

require_once '../../autoload.php';

// 只需要改这里就行了
$factoryObj = new UndergraduateFactory;

$xueLeiFeng = $factoryObj->CreateLeiFeng();

$xueLeiFeng->BuyRice();
$xueLeiFeng->Sweep();
$xueLeiFeng->Wash();


$student1 = $factoryObj->CreateLeiFeng();

$student1->BuyRice();
$student1->Sweep();
$student1->Wash();


$student2 = $factoryObj->CreateLeiFeng();

$student2->BuyRice();
$student2->Sweep();
$student2->Wash();


$student3 = $factoryObj->CreateLeiFeng();

$student3->BuyRice();
$student3->Sweep();
$student3->Wash();